import { DELETE, GET, POST } from '../axios.config.js'

const base = window.config.ip
const projectName = '/business'

// 获取企业名录列表
export const listEnterprisePages = p => GET(`${base}${projectName}/ZcEnterpriseDirectory/listEnterprisePages`, p)

// 获取企业详情
export const getEnterpriseDetail = p => GET(`${base}${projectName}/ZcEnterpriseDirectory/getEnterpriseDetail`, p)

// 删除企业
export const deleteEnterprise = id => DELETE(`${base}${projectName}/ZcEnterpriseDirectory/deleteEnterprise?id=${id}`)

// 新增企业名录
export const saveEnterprise = p => POST(`${base}${projectName}/ZcEnterpriseDirectory/saveEnterprise`, p)

// 企业审批
export const approvalEnterpriseApi = p => POST(`${base}${projectName}/ZcApprovalRecord/approvalEnterprise`, p)

// 获取审批记录列表
export const listApprovalRecordApi = p => GET(`${base}${projectName}/ZcApprovalRecord/listApprovalRecord`, p)

// 获取委员信息列表
export const getMemberListApi = p => GET(`${base}${projectName}/trCommitteeMember/getMemberList`, p)

// 删除委员信息
export const deleteMemberByIdApi = id => DELETE(`${base}${projectName}/trCommitteeMember/deleteMemberById?id=${id}`)
